home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
ftp.cs.arizona.edu
/
ftp.cs.arizona.edu.tar
/
ftp.cs.arizona.edu
/
icon
/
newsgrp
/
group96a.txt
/
000007_icon-group-sender _Fri Jan 5 20:26:00 1996.msg
< prev
next >
Wrap
Internet Message Format
|
1996-09-05
|
3KB
Received: by cheltenham.cs.arizona.edu; Mon, 8 Jan 1996 06:09:30 MST
Message-Id: <m0tYOL4-001I07C@ns1.computek.net>
Date: Fri, 5 Jan 96 20:26 CST
Mime-Version: 1.0
Content-Type: text/plain
Content-Transfer-Encoding: 7bit
From: gep2@computek.net
Subject: Re: How does Icon compare to Perl?
To: icon-group@cs.arizona.edu
X-Mailer: SPRY Mail Version: 04.00.06.17
Errors-To: icon-group-errors@cs.arizona.edu
Status: O
>I've looked over Perl and it seems like what I'd expect from
an early cut at Icon (i.e. V1.0).
Actually, a year or two ago I took a Perl program that a French friend was
really thrilled with (so easy, so compact, etc. etc.) and rewrote it in SNOBOL4+
with very little effort... and my SNOBOL4+ version was about half the size of
his original Perl program.
My general feeling is that Perl would be a wonderful tool, if SNOBOL4 and Icon
didn't exist. But they DO exist, so why put up with a halfassed dog like Perl?
>It has regular expression pattern matching which some deem extremely cool.
How so? RegExs are really pitiful compared to a real SNOBOL4-style pattern
match or an Icon-style string scanning expression. Who needs a "poor man's"
pattern match, when you can have the real thing?
>Perl is interpreted like old BASIC is interpreted. Each line has
to be freshly loaded and parsed during execution, whereas, even
an "interpreted" Icon program uses a pre-digested icode. Perl
programmers claim this is their plus, they can edit-run-edit-run
where Icon programmers have to edit-compile-run-edit-compile-run.
In the case of SNOBOL4 you compile-and-run in a single step, and compilation
time (even moreso than for Icon) is generally essentially trivial. Although you
CAN pre-compile your programs if you want, which can be useful if you want to
sell your programs and don't want to distribute them in source form.
>I think it's possible to write Perl code that looks like Icon and
maybe even to write Icon that looks like Perl (I don't why).
You certainly can't write anything so easily in Perl that handles the kinds of
multivalued expressions and goal-directed evaluation that you have in Icon! I
don't see that Perl implements anything more than a very small and limited,
primitive subset of either SNOBOL4 or Icon. Honestly, if you have and know
either or both of Icon or SNOBOL4, I don't see much (if any at all) point in
wasting time on Perl too.
Gordon Peterson
http://www.computek.net/public/gep2/